<form action="" class="form-horizontal" role="form">
  
  <div class="form-group">
    <label class="col-sm-2 control-label">活动名称</label>
    <div class="col-sm-4">
      <input type="text" class="form-control" name="config[name]" placeholder="请输入商品名称" datatype="*" value="{$config.name}">
    </div>
  </div>
  
  <div class="form-group">
    <label class="col-sm-2 control-label">开始时间</label>
    <div class="col-sm-2">
      <input type="text" id="begin-time" class="form-control" name="config[begin_time]" placeholder="选择活动开始的时间" datatype="*" value="{$config['begin_time'] ? date('Y-m-d H:i', $config['begin_time']) : ''}">
    </div>
  </div>
  
  <div class="form-group">
    <label class="col-sm-2 control-label">结束时间</label>
    <div class="col-sm-2">
      <input type="text" id="end-time" class="form-control" name="config[end_time]" placeholder="选择活动结束的时间" datatype="*" value="{$config['end_time'] ? date('Y-m-d H:i', $config['end_time']) : ''}">
    </div>
  </div>
  
  <div class="form-group">
    <div class="col-sm-offset-2 col-sm-8">
      <button type="submit" class="btn btn-primary submit" data-loading-txt="提交中，请稍后……" data-ajax-url="__CONTROLLER__/configPost">保存更改</button>
    </div>
  </div>
  
</form>

<!-- datetimepicker -->
<link rel="stylesheet" href="__PUBLIC__/Style/Common/datetimepicker/bootstrap-datetimepicker.min.css">
<script src="__PUBLIC__/Style/Common/datetimepicker/bootstrap-datetimepicker.min.js"></script>
<script src="__PUBLIC__/Style/Common/datetimepicker/bootstrap-datetimepicker.zh-CN.js"></script>
<script type="text/javascript">
  $(function(){
    
    $("#begin-time").datetimepicker({
      "language": "zh-CN"
    });
    
    $("#end-time").datetimepicker({
      "language": "zh-CN"
    });
  });
</script>